<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
	<head>
		<th:block th:include="include :: header('定时任务详细')" />
        <style type="text/css">
            .detail-label {
                background: none;
                font-size: 13px;
                font-weight: normal;
                text-shadow: none;
                line-height: 34px;
                height: 34px;
            }
        </style>
	</head>
	<body class="white-bg">
		<div class="wrapper wrapper-content animated fadeInRight ibox-content">
			<form class="form-horizontal m-t" id="jobLogForm" th:if="${name == 'jobLog'}">
                <div class="form-group">
                    <label class="col-sm-3 control-label">日志序号：</label>
                    <div class="label detail-label" th:text="${jobLog.jobLogId}"></div>
                </div>
                <div class="form-group">
                    <label class="col-sm-3 control-label">任务名称：</label>
                    <div class="label detail-label" th:text="${jobLog.jobName}"></div>
                </div>
				<div class="form-group">
					<label class="col-sm-3 control-label">任务分组：</label>
                    <div class="label detail-label" th:text="${@dict.getLabel('sys_job_group', jobLog.jobGroup)}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">调用目标字符串：</label>
					<div class="label detail-label" th:text="${jobLog.invokeTarget}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">日志信息：</label>
					<div class="label detail-label" th:text="${jobLog.jobMessage}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">执行状态：</label>
                    <div style="line-height: 34px;" th:class="${jobLog.status == '0' ? 'label label-primary' : 'label label-danger'}">[[${jobLog.status == '0' ? '正常' : '暂停'}]]</div>
				</div>
				<div class="form-group" th:style="'display:' + ${jobLog.status == '0' ? 'none' : 'block'}">
					<label class="col-sm-3 control-label">异常信息：</label>
					<div class="label detail-label" th:text="${jobLog.exceptionInfo}"></div>
				</div>
			</form>

			<form class="form-horizontal m-t" id="jobForm" th:if="${name == 'job'}">
			    <div class="form-group">
					<label class="col-sm-3 control-label">任务序号：</label>
					<div class="label detail-label" th:text="${job.jobId}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">任务名称：</label>
					<div class="label detail-label" th:text="${job.jobName}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">任务分组：</label>
					<div class="label detail-label" th:text="${job.jobGroup}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">调用目标字符串：</label>
					<div class="label detail-label" th:text="${job.invokeTarget}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">执行表达式：</label>
					<div class="label detail-label" th:text="${job.cronExpression}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">下次执行时间：</label>
					<div class="label detail-label" th:text="${#dates.format(job.nextValidTime, 'yyyy-MM-dd HH:mm:ss')}"></div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">执行策略：</label>
					<div class="label detail-label" th:if="${job.misfirePolicy == '0'}">默认策略</div>
					<div class="label detail-label" th:if="${job.misfirePolicy == '1'}">立即执行</div>
					<div class="label detail-label" th:if="${job.misfirePolicy == '2'}">执行一次</div>
					<div class="label detail-label" th:if="${job.misfirePolicy == '3'}">放弃执行</div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">并发执行：</label>
                    <div style="line-height: 34px;" th:class="${job.concurrent == '0' ? 'label label-primary' : 'label label-danger'}">
                        [[${job.concurrent == '0' ? '允许' : '禁止'}]]</div>
				</div>
				<div class="form-group">
					<label class="col-sm-3 control-label">执行状态：</label>
                    <div style="line-height: 34px;" th:class="${job.status == '0' ? 'label label-primary' : 'label label-danger'}">[[${job.status == '0' ? '正常' : '暂停'}]]</div>
				</div>
			</form>
	    </div>
	</body>
</html>